<?php

namespace App\Http\Models;

use Illuminate\Database\Eloquent\Model;

/**
 * App\Http\Models\Decode
 *
 * @property int $id
 * @property string|null $name 解析名称
 * @property string|null $param 解析参数
 * @property string|null $url 解析地址
 * @property \Illuminate\Support\Carbon|null $created_at
 * @property \Illuminate\Support\Carbon|null $updated_at
 * @property int|null $isdelete 1正常0冻结
 * @method static \Illuminate\Database\Eloquent\Builder|Decode newModelQuery()
 * @method static \Illuminate\Database\Eloquent\Builder|Decode newQuery()
 * @method static \Illuminate\Database\Eloquent\Builder|Decode query()
 * @method static \Illuminate\Database\Eloquent\Builder|Decode whereCreatedAt($value)
 * @method static \Illuminate\Database\Eloquent\Builder|Decode whereId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|Decode whereIsdelete($value)
 * @method static \Illuminate\Database\Eloquent\Builder|Decode whereName($value)
 * @method static \Illuminate\Database\Eloquent\Builder|Decode whereParam($value)
 * @method static \Illuminate\Database\Eloquent\Builder|Decode whereUpdatedAt($value)
 * @method static \Illuminate\Database\Eloquent\Builder|Decode whereUrl($value)
 * @mixin \Eloquent
 */
class Decode extends Model
{
    //影视解析表模型
    protected $table = 'decode';

    /**
     * 随机获取一条影视解析接口
     * @return Decode|\Illuminate\Database\Eloquent\Builder|Model|\Illuminate\Database\Query\Builder|null|object
     */
    public static function info()
    {
        return self::where('isdelete',1)->inRandomOrder()->first();
    }

}
